﻿<local:DocumentBase x:Class="WPFExcelReport.VKPOS"
                    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
                    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
                    xmlns:local="clr-namespace:ReflectionStudio.Components.UserControls;assembly=ReflectionStudio.Core"
                    xmlns:db="clr-namespace:ReflectionStudio.Core.Database;assembly=ReflectionStudio.Core" 
                    xmlns:wep="clr-namespace:WPFExcelReport"
                    xmlns:ucd="clr-namespace:ReflectionStudio.Controls;assembly=ReflectionStudio.Controls"
                    Loaded="Window_Loaded" >
    <local:DocumentBase.Resources>
        <CollectionViewSource  x:Key="viewVKPOS" >
        </CollectionViewSource>
    </local:DocumentBase.Resources>
    <Grid x:Uid="MasterGrid" Name="MasterGrid" DataContext=""  HorizontalAlignment="Stretch"  Margin="0,0,0,0"  VerticalAlignment="Stretch" UIElement.PreviewKeyDown="Grid_PreviewKeyDown">
        <Grid.RowDefinitions>
            <RowDefinition  Height="1000" />
        </Grid.RowDefinitions>
        <Grid.ColumnDefinitions>
            <ColumnDefinition x:Uid="ColumnDefinition_1" Width="300" />
            <ColumnDefinition x:Uid="ColumnDefinition_2" Width="300" />
            <ColumnDefinition x:Uid="ColumnDefinition_3" Width="400" />
        </Grid.ColumnDefinitions>
        <StackPanel x:Uid="StackPanel_1" Grid.Row="0" Grid.Column="0" Grid.ColumnSpan="2" HorizontalAlignment="Stretch" MaxHeight="900">
            <Expander x:Uid="expQueryCond" Name="expQueryCond"  ExpandDirection="Down" IsExpanded="True">
                <StackPanel x:Uid="StackPanel_2">
                    <StackPanel x:Uid="StackPanel_3">
                        <WrapPanel  x:Uid="zoneCommand" Name="zoneCommand" Height="26" Margin="0,0,0,6">
                            <Label x:Uid="Label_1" Content="系统"    Width="Auto" Margin="0,0,0,0"   HorizontalAlignment="Left"     VerticalAlignment="Center" />
                            <TextBox x:Uid="txtMANDANT" Name="txtMANDANT" MaxLength="2" Width="40" Margin="0,0,0,0" Text="00" HorizontalAlignment="Left" Background="Pink" FontSize="18"/>
                            <Label x:Uid="Label_2" Content="语言"    Width="Auto" Margin="0,0,0,0"   HorizontalAlignment="Left"     VerticalAlignment="Center" />
                            <TextBox  x:Uid="txtSPRACHKZ" IsReadOnly="True" Name="txtSPRACHKZ" Width="40" Margin="0,0,0,0" Text="" MaxLength="1"  HorizontalAlignment="Left" Background="Pink"  />
                            <Label x:Uid="Label_3" Content="日期" 
                                   Width="Auto" Margin="10,0,0,0"   HorizontalAlignment="Left"     VerticalAlignment="Center" />
                            <TextBox x:Uid="txtDATE" Name="txtDATE"  Width="80" Margin="0,0,0,0" Text=""  HorizontalAlignment="Left" Background="#FF62EF62"   MaxLength="8" AcceptsTab="True"  KeyboardNavigation.TabIndex="0"
                                     />
                            <Label x:Uid="Label_4" Content="用户名" 
                                   Width="Auto" Margin="0,0,0,0"   HorizontalAlignment="Left"     VerticalAlignment="Center" />
                            <TextBox x:Uid="txtUserID" Name="txtUserID"  Width="60" Margin="0,0,0,0" Text=""  HorizontalAlignment="Left" Background="Yellow"   MaxLength="8" AcceptsTab="True" CharacterCasing="Upper" KeyboardNavigation.TabIndex="0"
                                     />
                            <Label x:Uid="Label_5" Content="密码"    Width="Auto" Margin="0,0,0,0"   HorizontalAlignment="Left"     VerticalAlignment="Center" />
                            <PasswordBox x:Uid="txtPassword" Name="txtPassword" Width="80" Margin="10,0,0,0"   HorizontalAlignment="Left" Background="Yellow"   KeyboardNavigation.TabIndex="1" />
                            <Button  x:Uid="btnLogIn" Content="登录验证"   Width="Auto" Height="34" Margin="10,0,0,0"  Name="btnLogIn" Click="btnLogIn_Click"  KeyboardNavigation.TabIndex="2"
                                     IsDefault="True"
                                     />
                        </WrapPanel>
                        <WrapPanel x:Uid="WrapPanel_1">
                            <Label x:Uid="Label_6" Content="前缀"    Width="Auto" Margin="10,0,0,0"   HorizontalAlignment="Left"   FontSize="18" VerticalAlignment="Center" />
                            <TextBox x:Uid="txtKRS" Name="txtKRS" Width="38" Margin="10,0,0,0" Text=""  HorizontalAlignment="Left" Background="Pink" FontSize="18" MaxLength="2" AcceptsTab="True" CharacterCasing="Upper" />
                            <Label x:Uid="Label_7" Content="单号"    Width="Auto" Margin="10,0,0,0" HorizontalAlignment="Left"   FontSize="18" VerticalAlignment="Center" />
                            <TextBox x:Uid="txtLFD" Name="txtLFD" Width="74" Margin="10,0,0,0" Text="" HorizontalAlignment="Left" Background="Beige" FontSize="18" Height="30" MaxLength="6" AcceptsTab="True" AcceptsReturn="True" CharacterCasing="Upper" />
                            <Button  x:Uid="btnQuery" Content="查询"  IsEnabled="False"   Margin="10,0,0,0"  Name="btnQuery" Width="Auto" Click="btnQuery_Click" />
                            <Button x:Uid="btnPrint" Content="打印报表" Margin="10,0,0,0"   Name="btnPrint" Width="90" Click="btnPrint_Click" IsEnabled="False" Visibility="Hidden" />
                            <Button x:Uid="btnPrintPreview" Content="浏览数据"  Margin="10,0,0,0"    Name="btnPrintPreview" Width="90" Click="btnPrintPreview_Click" IsEnabled="False" Visibility="Hidden" />
                        </WrapPanel>
                    </StackPanel>
                    <DataGrid 
            x:Uid="dgVKKOPF" AutoGenerateColumns="False" EnableRowVirtualization="True"  
                                               ItemsSource="{Binding}"  
                                            HeadersVisibility="Column"
                                              x:Name="dgVKKOPF" 
                                                 CanUserReorderColumns="True"  
                                             CanUserResizeRows="True"
                                              CanUserSortColumns="True"
                                               
                                              RowDetailsVisibilityMode="VisibleWhenSelected"   
                                              Width="Auto"
                                              Height="Auto"
                                              EnableColumnVirtualization="True"  
                                              ScrollViewer.HorizontalScrollBarVisibility="Auto"
                                              ScrollViewer.VerticalScrollBarVisibility="Auto" SelectionChanged="dgVKKOPF_SelectionChanged">
                        <DataGrid.Columns>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_1" Binding="{Binding Path=VKKKUNDNR}" Header="客户号"   Width="SizeToHeader"  MinWidth="40"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_2" Binding="{Binding Path=KDKUNDNA}" Header="客户名"   Width="SizeToHeader"  MinWidth="80"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_3" Binding="{Binding Path=VKKVB}" Header="结算币种" Width="SizeToHeader"  MinWidth="80"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_4" Binding="{Binding Path=VKKSACHBE}" Header="联系人" Width="SizeToHeader" MinWidth="60"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_5" Binding="{Binding Path=VKKZAHLBED}" Header="付款方式"      Foreground ="Red" Width="SizeToHeader"  MinWidth="60"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_6" Binding="{Binding Path=VKKLIEFBED}" Header="发货条件"     Foreground="Red" Width="SizeToHeader" MinWidth="20"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_7" Binding="{Binding Path=VKKVERSART}" Header="运输方式"     Foreground="Red" Width="SizeToHeader" MinWidth="20"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_8" Binding="{Binding Path=VKKBESTNR}" Header="销售合同"     Foreground="Red" Width="SizeToHeader" MinWidth="20"/>
                        </DataGrid.Columns>
                    </DataGrid>
                    <DataGrid 
                        x:Uid="dgVKPOS" AutoGenerateColumns="False" EnableRowVirtualization="True"  
                        ItemsSource="{Binding}"  
                        HeadersVisibility="Column"
                        x:Name="dgVKPOS"  
                        CanUserReorderColumns="True"  
                        CanUserResizeRows="True"
                        CanUserSortColumns="True"
                         
                        RowDetailsVisibilityMode="VisibleWhenSelected"   
                        Width="Auto"
                        Height="Auto"
                        EnableColumnVirtualization="True"  
                        ScrollViewer.HorizontalScrollBarVisibility="Auto"
                        ScrollViewer.VerticalScrollBarVisibility="Auto" 
                        >
                        <DataGrid.Columns>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_9" Binding="{Binding Path=VKPART}" Header="品种"   Width="SizeToCells"  MinWidth="40"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_10" Binding="{Binding Path=VKPFARBE}" Header="颜色"   Width="SizeToCells"  MinWidth="40"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_11" Binding="{Binding Path=VKPPOSTYP}" Header="类型"   Width="SizeToCells"  MinWidth="40"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_12" Binding="{Binding Path=VKPKDBEZ}" Header=""      Foreground ="Red" Width="SizeToCells"  MinWidth="100"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_13" Binding="{Binding Path=VKPKDARTNR}" Header="规格"      Foreground ="Red" Width="SizeToCells"  MinWidth="100"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_14" Binding="{Binding Path=VKPKDFARBNR}" Header="" Width="SizeToCells" MinWidth="100"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_15" Binding="{Binding Path=VKPMENGE1}" Header="数量"     Foreground="Red" Width="SizeToCells" MinWidth="40"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_16" Binding="{Binding Path=VKPMEEH}" Header="单位"     Foreground="Red" Width="SizeToCells" MinWidth="40"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_17" Binding="{Binding Path=VKPLIEFTERM}" Header="交期"     Foreground="Red" Width="SizeToCells" MinWidth="40"/>
                        </DataGrid.Columns>
                    </DataGrid>
                </StackPanel>
            </Expander>
            <ScrollViewer x:Uid="ScrollViewer_1" HorizontalScrollBarVisibility="Visible" VerticalScrollBarVisibility="Visible" MaxHeight="600">
                <Grid x:Uid="Grid_1" Background="White"  DataContext="{Binding ElementName=dgVKPOS, Path=SelectedItem}" HorizontalAlignment="Left" Margin="0,0,0,0"  VerticalAlignment="Top"  >
                    <Grid.ColumnDefinitions>
                        <ColumnDefinition x:Uid="ColumnDefinition_4" Width="70" />
                        <ColumnDefinition x:Uid="ColumnDefinition_5" Width="515" />
                    </Grid.ColumnDefinitions>
                    <Grid.RowDefinitions>
                        <RowDefinition x:Uid="RowDefinition_2" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_3" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_4" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_5" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_6" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_7" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_8" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_9" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_10" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_11" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_12" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_13" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_14" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_15" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_16" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_17" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_18" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_19" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_20" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_21" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_22" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_23" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_24" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_25" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_26" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_27" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_28" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_29" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_30" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_31" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_32" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_33" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_34" Height="Auto" />
                        <RowDefinition x:Uid="RowDefinition_35" Height="Auto" />
                    </Grid.RowDefinitions>
                    <WrapPanel x:Uid="WrapPanel_2" Grid.Row="0" Grid.Column="0" Grid.ColumnSpan="2">
                        <Label  x:Uid="Label_8" Width="Auto" Content="任务书编号:"  HorizontalAlignment="Left" Margin="3"   VerticalAlignment="Center"  />
                        <TextBlock  x:Uid="TextBlock_1" HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=VKPAUFKRS, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="40" />
                        <TextBlock x:Uid="TextBlock_2">/</TextBlock>
                        <TextBlock  x:Uid="TextBlock_3" HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=VKPAUFLFD, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="80" />
                        <TextBlock x:Uid="TextBlock_4" Width="Auto"   >合同编号:</TextBlock>
                        <TextBlock  x:Uid="TextBlock_5" HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=VKKBESTNR, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="180" />
                        <TextBlock x:Uid="TextBlock_6" Width="Auto"   >日期:</TextBlock>
                        <TextBlock  x:Uid="TextBlock_7" HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=VKKBESTDAT, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="80" />
                    </WrapPanel>
                    <TextBlock x:Uid="TextBlock_8" Width="Auto"    Grid.Row="1" Grid.Column="0">经营部:</TextBlock>
                    <TextBlock x:Uid="TextBlock_9" Width="Auto"    Grid.Row="2" Grid.Column="0">客户:</TextBlock>
                    <TextBox    x:Uid="TextBox_1" Grid.Row="2" Grid.Column="1" Height="Auto" HorizontalAlignment="Left" Text="{Binding Path=KDNAME1, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="515" />
                    <TextBlock x:Uid="TextBlock_10" Width="Auto"    Grid.Row="3" Grid.Column="0">组织规格:</TextBlock>
                    <WrapPanel  x:Uid="WrapPanel_3" Grid.Row="3" Grid.Column="1">
                        <TextBlock  x:Uid="TextBlock_11" HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=VKPKDBEZ, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" MinWidth="40" Width="Auto" />
                        <TextBlock  x:Uid="TextBlock_12" HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=VKPKDARTNR, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" MinWidth="40" Width="Auto" />
                        <TextBlock  x:Uid="TextBlock_13" HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=VKPKDFARBNR, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" MinWidth="40" Width="Auto" />
                    </WrapPanel>
                    <TextBlock x:Uid="TextBlock_14" Width="Auto"    Grid.Row="4" Grid.Column="0">质量要求:</TextBlock>
                    <TextBox    x:Uid="KVKTTXT01" Name="KVKTTXT01" IsReadOnly="False" Grid.Row="4" Grid.Column="1"  HorizontalAlignment="Left" Text="{Binding Path=KVKTTXT01, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="515" IsTabStop="True" KeyboardNavigation.TabIndex="3" MaxLength="72" />
                    <TextBlock x:Uid="TextBlock_15" Width="Auto"   Grid.Row="5" Grid.Column="0">交布条件:</TextBlock>
                    <TextBox    x:Uid="KVKTTXT02" Name="KVKTTXT02"  IsReadOnly="True" Grid.Row="5" Grid.Column="1"  HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=KVKTTXT02, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="515"  KeyboardNavigation.TabIndex="4"
                                 />
                    <TextBlock x:Uid="TextBlock_16" Width="Auto"    Grid.Row="6" Grid.Column="0">织坯数量:</TextBlock>
                    <WrapPanel  x:Uid="WrapPanel_4" Grid.Row="6" Grid.Column="1">
                        <TextBlock  x:Uid="TextBlock_17" HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=VKPMENGE1, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="Auto" MinWidth="60" />
                        <TextBlock   x:Uid="TextBlock_18" HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=VKPMEEH, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="Auto" MinWidth="20" />
                        <TextBlock x:Uid="TextBlock_19">(</TextBlock>
                        <TextBox   x:Uid="KVKTTXT03" Name="KVKTTXT03"  HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=KVKTTXT03, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="45" TextWrapping="NoWrap" KeyboardNavigation.TabIndex="5"
                                 />
                        <TextBlock x:Uid="TextBlock_20">)</TextBlock>
                    </WrapPanel>
                    <TextBlock x:Uid="TextBlock_21" Width="Auto"   Grid.Row="7" Grid.Column="0">坯布颜色:</TextBlock>
                    <WrapPanel  x:Uid="WrapPanel_5" Grid.Row="7" Grid.Column="1">
                        <TextBlock     x:Uid="TextBlock_22" HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=VKPFARBE, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="40" />
                        <TextBlock x:Uid="TextBlock_23">(</TextBlock>
                        <TextBox    x:Uid="KVKTTXT04" Name="KVKTTXT04" IsReadOnly="True"  HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=KVKTTXT04 , Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="465" TextWrapping="NoWrap"  KeyboardNavigation.TabIndex="6"
                                 />
                        <TextBlock x:Uid="TextBlock_24">)</TextBlock>
                    </WrapPanel>
                    <TextBlock    x:Uid="TextBlock_25" Grid.Row="8" Grid.Column="0">包装标准:</TextBlock>
                    <WrapPanel  x:Uid="WrapPanel_6" Grid.Row="8" Grid.Column="1">
                        <TextBlock     x:Uid="TextBlock_26" HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=VKPAUFMART, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="40" />
                        <TextBlock     x:Uid="TextBlock_27" HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=VKPVERPART, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="40" />
                        <TextBlock x:Uid="TextBlock_28">(</TextBlock>
                        <TextBox    x:Uid="KVKTTXT12" Name="KVKTTXT12" Tag="EDIT_VK"  IsReadOnly="True"  HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=KVKTTXT12, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="424" KeyboardNavigation.TabIndex="7"
                                 />
                        <TextBlock x:Uid="TextBlock_29">)</TextBlock>
                    </WrapPanel>
                    <TextBlock   x:Uid="TextBlock_30" Grid.Row="9" Grid.Column="0">原料价格:</TextBlock>
                    <TextBox    x:Uid="KVKTTXT05" Name="KVKTTXT05"  Tag="EDIT_VK" IsReadOnly="True" Grid.Row="9" Grid.Column="1"  HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=KVKTTXT05, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="515"  KeyboardNavigation.TabIndex="8"
                                 />
                    <TextBox    x:Uid="KVKTTXT06" Name="KVKTTXT06"  Tag="EDIT_VK"  IsReadOnly="True" Grid.Row="10" Grid.Column="1"  HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=KVKTTXT06, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="515"  KeyboardNavigation.TabIndex="9"
                                 />
                    <TextBlock   x:Uid="TextBlock_31" Grid.Row="11" Grid.Column="0">交期:</TextBlock>
                    <WrapPanel x:Uid="WrapPanel_7" Grid.Row="11" Grid.Column="1">
                        <TextBlock     x:Uid="TextBlock_32" HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=VKPLIEFTERM, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="80" />
                        <TextBlock x:Uid="TextBlock_33">(</TextBlock>
                        <TextBox    x:Uid="KVKTTXT07" Name="KVKTTXT07"  Tag="EDIT_VK" IsReadOnly="True"  HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=KVKTTXT07, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="429"  KeyboardNavigation.TabIndex="10"
                                 />
                        <TextBox     x:Uid="KVKTTXT08" Name="KVKTTXT08" Tag="EDIT_VK"  IsReadOnly="True" HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=KVKTTXT08, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="508"  KeyboardNavigation.TabIndex="11"
                                 />
                        <TextBlock x:Uid="TextBlock_34">)</TextBlock>
                    </WrapPanel>
                    <TextBlock    x:Uid="TextBlock_35" Grid.Row="13" Grid.Column="0">备       注:</TextBlock>
                    <StackPanel x:Uid="StackPanel_4" Grid.Row="13" Grid.Column="1">
                        <TextBox    x:Uid="KVKTTXT09" Name="KVKTTXT09" Tag="EDIT_VK"  IsReadOnly="True"  HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=KVKTTXT09, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="515"  KeyboardNavigation.TabIndex="12"
                                 />
                        <TextBox    x:Uid="KVKTTXT10" Name="KVKTTXT10" Tag="EDIT_VK"  IsReadOnly="True"   HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=KVKTTXT10, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="515"  KeyboardNavigation.TabIndex="13"
                                 />
                        <TextBox    x:Uid="KVKTTXT11" Name="KVKTTXT11" Tag="EDIT_VK" IsReadOnly="True"  HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=KVKTTXT11, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="515"  KeyboardNavigation.TabIndex="14"
                                 />
                    </StackPanel>
                    <WrapPanel x:Uid="WrapPanel_8" Grid.Row="17" Grid.Column="1" HorizontalAlignment="Right">
                        <TextBlock x:Uid="TextBlock_36"     >经营部长:______________</TextBlock>
                        <TextBlock x:Uid="TextBlock_37"    > 经营副总经理:____________</TextBlock>
                        <Button    x:Uid="Button_1" Content="编辑" IsEnabled="True" Tag="EDIT_VK"  Margin="0,0,0,0"    Width="75" Click="btnUpload_Click" />
                    </WrapPanel>
                    <TextBlock    x:Uid="TextBlock_38" Grid.Row="18" Grid.Column="0">生产部：</TextBlock>
                    <TextBox    x:Uid="PVKTTXT01" Name="PVKTTXT01" Tag="EDIT_TE" IsReadOnly="True" Grid.Row="18" Grid.Column="1" HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=PVKTTXT01, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="515"  KeyboardNavigation.TabIndex="15"
                                 />
                    <TextBox     x:Uid="PVKTTXT02" Name="PVKTTXT02" Tag="EDIT_TE"  IsReadOnly="True" Grid.Row="19" Grid.Column="1" HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=PVKTTXT02, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="515"  KeyboardNavigation.TabIndex="16"
                                 />
                    <TextBox    x:Uid="PVKTTXT03" Name="PVKTTXT03" Tag="EDIT_TE" IsReadOnly="True" Grid.Row="20" Grid.Column="1" HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=PVKTTXT03, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="515"  KeyboardNavigation.TabIndex="17"
                                 />
                    <TextBox    x:Uid="PVKTTXT04" Name="PVKTTXT04" Tag="EDIT_TE"  IsReadOnly="True" Grid.Row="21" Grid.Column="1" HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=PVKTTXT04, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="515" KeyboardNavigation.TabIndex="18"
                                 />
                    <TextBox    x:Uid="PVKTTXT05" Name="PVKTTXT05" Tag="EDIT_TE"  IsReadOnly="True" Grid.Row="22" Grid.Column="1" HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=PVKTTXT05, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="515"  KeyboardNavigation.TabIndex="19"
                                 />
                    <WrapPanel x:Uid="WrapPanel_9" Grid.Row="23" Grid.Column="1"  HorizontalAlignment="Right">
                        <TextBlock x:Uid="TextBlock_39" >工艺员：___________________</TextBlock>
                        <Button  x:Uid="Button_2" Content="编辑" IsEnabled="True" Tag="EDIT_TE"  Margin="10,0,0,0"    Width="75" Click="btnUpload_Click" />
                    </WrapPanel>
                    <TextBox    x:Uid="PVKTTXT06" Name="PVKTTXT06" Tag="EDIT_TEM"  IsReadOnly="True" Grid.Row="24" Grid.Column="1" HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=PVKTTXT06, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="515"  KeyboardNavigation.TabIndex="20"
                                 />
                    <TextBox    x:Uid="PVKTTXT07" Name="PVKTTXT07" Tag="EDIT_TEM" IsReadOnly="True" Grid.Row="25" Grid.Column="1" HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=PVKTTXT07, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="515" KeyboardNavigation.TabIndex="21"
                                 />
                    <TextBox    x:Uid="PVKTTXT08" Name="PVKTTXT08" Tag="EDIT_TEM" IsReadOnly="True" Grid.Row="26" Grid.Column="1" HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=PVKTTXT08, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="515"  KeyboardNavigation.TabIndex="22"
                                 />
                    <WrapPanel x:Uid="WrapPanel_10" Grid.Row="27" Grid.Column="1" HorizontalAlignment="Right">
                        <TextBlock x:Uid="TextBlock_40"   >工艺主任：_________________</TextBlock>
                        <Button    x:Uid="Button_3" Content="编辑" IsEnabled="True" Tag="EDIT_TEM"  Margin="10,0,0,0"    Width="75" Click="btnUpload_Click" />
                    </WrapPanel>
                    <TextBlock    x:Uid="TextBlock_41" Grid.Row="28" Grid.Column="0">原料采购部：</TextBlock>
                    <StackPanel  x:Uid="StackPanel_5" Grid.Row="28" Grid.Column="1">
                        <TextBox    x:Uid="PVKTTXT09" Name="PVKTTXT09"  IsReadOnly="True"   HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=PVKTTXT09, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="515"  KeyboardNavigation.TabIndex="23"
                                 />
                        <TextBox    x:Uid="PVKTTXT10" Name="PVKTTXT10" Tag="EDIT_EK"   IsReadOnly="True" HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=PVKTTXT10, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="515"  KeyboardNavigation.TabIndex="24"
                                 />
                        <TextBox    x:Uid="PVKTTXT11" Name="PVKTTXT11" Tag="EDIT_EK"   IsReadOnly="True" HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=PVKTTXT11, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="515"  KeyboardNavigation.TabIndex="25"
                                 />
                        <TextBox    x:Uid="PVKTTXT12" Name="PVKTTXT12" Tag="EDIT_EK"   IsReadOnly="True" HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=PVKTTXT12, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="515"  KeyboardNavigation.TabIndex="25"
                                 />
                        <TextBox    x:Uid="PVKTTXT13" Name="PVKTTXT13" Tag="EDIT_EK"   IsReadOnly="True" HorizontalAlignment="Left" Margin="0,0,0,0"  Text="{Binding Path=PVKTTXT13, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" Background="White" VerticalAlignment="Center" Width="515"  KeyboardNavigation.TabIndex="25"
                                 />
                    </StackPanel>
                    <WrapPanel x:Uid="WrapPanel_11" Grid.Row="31" Grid.Column="1" HorizontalAlignment="Right">
                        <TextBlock    x:Uid="TextBlock_42" HorizontalAlignment="Right">采购员：___________________</TextBlock>
                        <Button    x:Uid="Button_4" Content="编辑" IsEnabled="True" Tag="EDIT_EK"  Margin="10,0,0,0"    Width="75" Click="btnUpload_Click" />
                    </WrapPanel>
                    <TextBlock   x:Uid="TextBlock_43" Grid.Row="32" Grid.Column="0">送达部门：</TextBlock>
                    <WrapPanel x:Uid="WrapPanel_12" Grid.Row="32" Grid.Column="1">
                        <TextBlock x:Uid="TextBlock_44"   >经营副总经理：</TextBlock>
                        <TextBlock x:Uid="TextBlock_45"   >销售业务：</TextBlock>
                        <TextBlock x:Uid="TextBlock_46"   >品质部：</TextBlock>
                        <TextBlock x:Uid="TextBlock_47"   >资源部：</TextBlock>
                        <TextBlock x:Uid="TextBlock_48"   >织布：</TextBlock>
                        <TextBlock x:Uid="TextBlock_49"   >整理工序：</TextBlock>
                    </WrapPanel>
                    <TextBlock    x:Uid="TextBlock_50" Grid.Row="33" Grid.Column="0">签字确认：</TextBlock>
                    <WrapPanel x:Uid="WrapPanel_13" Grid.Row="33" Grid.Column="1">
                        <TextBlock x:Uid="TextBlock_51">————————</TextBlock>
                        <TextBlock x:Uid="TextBlock_52">————————</TextBlock>
                        <TextBlock x:Uid="TextBlock_53">————————</TextBlock>
                        <TextBlock x:Uid="TextBlock_54">————————</TextBlock>
                        <TextBlock x:Uid="TextBlock_55">————————</TextBlock>
                        <TextBlock x:Uid="TextBlock_56">————————</TextBlock>
                    </WrapPanel>
                </Grid>
            </ScrollViewer>
        </StackPanel>
        <Grid  x:Uid="Grid_2" Grid.Row="0" Grid.Column="2" DataContext=""  HorizontalAlignment="Stretch"   VerticalAlignment="Stretch" UIElement.PreviewKeyDown="Grid_PreviewKeyDown">
            <StackPanel x:Uid="StackPanel_6">
                <Button  x:Uid="btnRefresh" Name="btnRefresh" Click="btnRefresh_Click"  Width="24" HorizontalAlignment="Left" Height="21">
                    <Button.Background>
                        <ImageBrush x:Uid="ImageBrush_1" ImageSource="/IntexReportClient;component/Resources/Images/16x16/application/refresh.png" />
                    </Button.Background>
                </Button>
                <Expander  x:Uid="Expander_1" Header="新单" ExpandDirection="Down">
                    <DataGrid x:Uid="dgEDIT_TD" Grid.Row="0"
            AutoGenerateColumns="False" EnableRowVirtualization="True"  
                                  ItemsSource="{Binding}"  
                                  HeadersVisibility="Column"
                                  x:Name="dgEDIT_TD" 
                                  CanUserReorderColumns="True"  
                                  CanUserResizeRows="True"
                                  CanUserSortColumns="True"
                                   
                                  RowDetailsVisibilityMode="VisibleWhenSelected"   
                                  Width="Auto"
                               Height="Auto"
                                  EnableColumnVirtualization="True"  
                                  ScrollViewer.HorizontalScrollBarVisibility="Auto"
                                  ScrollViewer.VerticalScrollBarVisibility="Auto"
                                  SelectionChanged="DataGrid_SelectionChanged"
                                  >
                        <DataGrid.Columns>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_18" Binding="{Binding Path=VKPAUFKRS}" Header="" Width="SizeToCells"    MinWidth="20"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_19" Binding="{Binding Path=VKPAUFLFD}" Header="单号" Width="SizeToCells"    MinWidth="40"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_20" Binding="{Binding Path=VKPAUFPOS}" Header="" Width="SizeToCells"    MinWidth="30"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_21" Binding="{Binding Path=VKPKDBEZ}" Header=""       Width="SizeToCells"  MinWidth="100"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_22" Binding="{Binding Path=VKPKDARTNR}" Header="规格"     Foreground ="Red" Width="SizeToCells"  MinWidth="100"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_23" Binding="{Binding Path=VKPKDFARBNR}" Header=""   Width="SizeToCells" MinWidth="100"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_24" Binding="{Binding Path=VKPMENGE1}" Header="数量"    Foreground="Red" Width="SizeToCells" MinWidth="40"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_25" Binding="{Binding Path=VKPMEEH}" Header="单位"   Foreground="Red" Width="SizeToCells" MinWidth="40"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_26" Binding="{Binding Path=VKPLIEFTERM}" Header="交期"     Foreground="Red" Width="SizeToCells" MinWidth="40"/>
                        </DataGrid.Columns>
                    </DataGrid>
                </Expander>
                <Expander x:Uid="Expander_2" Header="销售已审核" ExpandDirection="Down">
                    <DataGrid x:Uid="dgEDIT_VK" Grid.Row="0"
            AutoGenerateColumns="False" EnableRowVirtualization="True"  
                                  ItemsSource="{Binding}"  
                                  HeadersVisibility="Column"
                                  x:Name="dgEDIT_VK" 
                                  CanUserReorderColumns="True"  
                                  CanUserResizeRows="True"
                                  CanUserSortColumns="True"
                                   
                                  RowDetailsVisibilityMode="VisibleWhenSelected"   
                                  Width="Auto"
                                 Height="Auto"
                                  EnableColumnVirtualization="True"  
                                  ScrollViewer.HorizontalScrollBarVisibility="Auto"
                                  ScrollViewer.VerticalScrollBarVisibility="Auto"
                                  SelectionChanged="DataGrid_SelectionChanged"
                                  >
                        <DataGrid.Columns>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_27" Binding="{Binding Path=VKPAUFKRS}" Header="" Width="SizeToCells"    MinWidth="20"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_28" Binding="{Binding Path=VKPAUFLFD}" Header="单号"    Width="SizeToCells"  MinWidth="40"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_29" Binding="{Binding Path=VKPAUFPOS}" Header=""    Width="SizeToCells"  MinWidth="30"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_30" Binding="{Binding Path=VKPKDBEZ}" Header=""     Foreground ="Red" Width="SizeToCells"  MinWidth="100"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_31" Binding="{Binding Path=VKPKDARTNR}" Header="规格"    Foreground ="Red" Width="SizeToCells"  MinWidth="100"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_32" Binding="{Binding Path=VKPKDFARBNR}" Header=""   Width="SizeToCells" MinWidth="100"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_33" Binding="{Binding Path=VKPMENGE1}" Header="数量"   Foreground="Red" Width="SizeToCells" MinWidth="40"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_34" Binding="{Binding Path=VKPMEEH}" Header="单位"    Foreground="Red" Width="SizeToCells" MinWidth="40"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_35" Binding="{Binding Path=VKPLIEFTERM}" Header="交期"     Foreground="Red" Width="SizeToCells" MinWidth="40"/>
                        </DataGrid.Columns>
                    </DataGrid>
                </Expander>
                <Expander x:Uid="Expander_3" Header="工艺已审核" ExpandDirection="Down">
                    <DataGrid x:Uid="dgEDIT_TE" Grid.Row="0"
            AutoGenerateColumns="False" EnableRowVirtualization="True"  
                                  ItemsSource="{Binding}"  
                                  HeadersVisibility="Column"
                                  x:Name="dgEDIT_TE" 
                                  CanUserReorderColumns="True"  
                                  CanUserResizeRows="True"
                                  CanUserSortColumns="True"
                                   
                                  RowDetailsVisibilityMode="VisibleWhenSelected"   
                                  Width="Auto"
                                   Height="Auto"
                                  EnableColumnVirtualization="True"  
                                  ScrollViewer.HorizontalScrollBarVisibility="Auto"
                                  ScrollViewer.VerticalScrollBarVisibility="Auto"
                                  SelectionChanged="DataGrid_SelectionChanged"
                                  >
                        <DataGrid.Columns>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_36" Binding="{Binding Path=VKPAUFKRS}" Header=""    Width="SizeToCells"  MinWidth="20"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_37" Binding="{Binding Path=VKPAUFLFD}" Header="单号"    Width="SizeToCells"  MinWidth="40"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_38" Binding="{Binding Path=VKPAUFPOS}" Header=""    Width="SizeToCells"  MinWidth="30"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_39" Binding="{Binding Path=VKPKDBEZ}" Header=""     Foreground ="Red" Width="SizeToCells"  MinWidth="100"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_40" Binding="{Binding Path=VKPKDARTNR}" Header="规格"     Foreground ="Red" Width="SizeToCells"  MinWidth="100"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_41" Binding="{Binding Path=VKPKDFARBNR}" Header=""    Width="SizeToCells" MinWidth="100"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_42" Binding="{Binding Path=VKPMENGE1}" Header="数量"     Foreground="Red" Width="SizeToCells" MinWidth="40"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_43" Binding="{Binding Path=VKPMEEH}" Header="单位"    Foreground="Red" Width="SizeToCells" MinWidth="40"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_44" Binding="{Binding Path=VKPLIEFTERM}" Header="交期"   Foreground="Red" Width="SizeToCells" MinWidth="40"/>
                        </DataGrid.Columns>
                    </DataGrid>
                </Expander>
                <Expander x:Uid="Expander_4" Header="工艺经理已审核" ExpandDirection="Down">
                    <DataGrid x:Uid="dgEDIT_TEM" Grid.Row="0"
            AutoGenerateColumns="False" EnableRowVirtualization="True"  
                                  ItemsSource="{Binding}"  
                                  HeadersVisibility="Column"
                                  x:Name="dgEDIT_TEM" 
                                  CanUserReorderColumns="True"  
                                  CanUserResizeRows="True"
                                  CanUserSortColumns="True"
                                   
                                  RowDetailsVisibilityMode="VisibleWhenSelected"   
                                  Width="Auto"
                                 Height="Auto"
                                  EnableColumnVirtualization="True"  
                                  ScrollViewer.HorizontalScrollBarVisibility="Auto"
                                  ScrollViewer.VerticalScrollBarVisibility="Auto"
                                  SelectionChanged="DataGrid_SelectionChanged"
                                  >
                        <DataGrid.Columns>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_45" Binding="{Binding Path=VKPAUFKRS}" Header=""    Width="SizeToCells"  MinWidth="20"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_46" Binding="{Binding Path=VKPAUFLFD}" Header="单号"    Width="SizeToCells"  MinWidth="40"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_47" Binding="{Binding Path=VKPAUFPOS}" Header=""    Width="SizeToCells"  MinWidth="30"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_48" Binding="{Binding Path=VKPKDBEZ}" Header=""      Foreground ="Red" Width="SizeToCells"  MinWidth="100"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_49" Binding="{Binding Path=VKPKDARTNR}" Header="规格"      Foreground ="Red" Width="SizeToCells"  MinWidth="100"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_50" Binding="{Binding Path=VKPKDFARBNR}" Header="" Width="SizeToCells" MinWidth="100"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_51" Binding="{Binding Path=VKPMENGE1}" Header="数量"     Foreground="Red" Width="SizeToCells" MinWidth="40"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_52" Binding="{Binding Path=VKPMEEH}" Header="单位"     Foreground="Red" Width="SizeToCells" MinWidth="40"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_53" Binding="{Binding Path=VKPLIEFTERM}" Header="交期"     Foreground="Red" Width="SizeToCells" MinWidth="40"/>
                        </DataGrid.Columns>
                    </DataGrid>
                </Expander>
                <Expander x:Uid="Expander_5" Header="采购已审核" ExpandDirection="Down">
                    <DataGrid x:Uid="dgEDIT_EK" Grid.Row="0"
            AutoGenerateColumns="False" EnableRowVirtualization="True"  
                                  ItemsSource="{Binding}"  
                                  HeadersVisibility="Column"
                                  x:Name="dgEDIT_EK" 
                                  CanUserReorderColumns="True"  
                                  CanUserResizeRows="True"
                                  CanUserSortColumns="True"
                                   
                                  RowDetailsVisibilityMode="VisibleWhenSelected"   
                                  Width="Auto"
                               Height="Auto"
                                  EnableColumnVirtualization="True"  
                                  ScrollViewer.HorizontalScrollBarVisibility="Auto"
                                  ScrollViewer.VerticalScrollBarVisibility="Auto"
                                  SelectionChanged="DataGrid_SelectionChanged"
                                  >
                        <DataGrid.Columns>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_54" Binding="{Binding Path=VKPAUFKRS}" Header=""    Width="SizeToCells"  MinWidth="20"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_55" Binding="{Binding Path=VKPAUFLFD}" Header="单号"    Width="SizeToCells"  MinWidth="40"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_56" Binding="{Binding Path=VKPAUFPOS}" Header=""    Width="SizeToCells"  MinWidth="30"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_57" Binding="{Binding Path=VKPKDBEZ}" Header=""      Foreground ="Red" Width="SizeToCells"  MinWidth="100"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_58" Binding="{Binding Path=VKPKDARTNR}" Header="规格"      Foreground ="Red" Width="SizeToCells"  MinWidth="100"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_59" Binding="{Binding Path=VKPKDFARBNR}" Header="" Width="SizeToCells" MinWidth="100"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_60" Binding="{Binding Path=VKPMENGE1}" Header="数量"     Foreground="Red" Width="SizeToCells" MinWidth="40"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_61" Binding="{Binding Path=VKPMEEH}" Header="单位"     Foreground="Red" Width="SizeToCells" MinWidth="40"/>
                            <DataGridTextColumn x:Uid="DataGridTextColumn_62" Binding="{Binding Path=VKPLIEFTERM}" Header="交期"     Foreground="Red" Width="SizeToCells" MinWidth="40"/>
                        </DataGrid.Columns>
                    </DataGrid>
                </Expander>
            </StackPanel>
        </Grid>
    </Grid>
</local:DocumentBase>
